//
//  vc3.m
//  DemoProject
//
//  Created by liu xiwang on 2018/4/11.
//  Copyright © 2018年 Sunqk. All rights reserved.
//

#import "vc3.h"

@interface vc3 ()

@property (nonatomic,strong)UIButton  * btnToVC2;

@end

@implementation vc3

- (void)viewDidLoad {
    [super viewDidLoad];
    [self setUpView];
}

- (void)viewWillAppear:(BOOL)animated {
    [super viewWillAppear:animated];
    
}

-(void)viewWillDisappear:(BOOL)animated{
    [super viewWillDisappear:animated];
    
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
}

- (void)dealloc {
    
}

#pragma mark   UI
-(void)setUpView{
    [self setUseCustomNav:YES];
    self.navigationItem.title = @"个人";
    [self.view addSubview:self.btnToVC2];
    self.customNavBar.backgroundColor = [UIColor redColor];
    [self.view updateConstraintsIfNeeded];
}

- (void)updateViewConstraints {
    [super updateViewConstraints];
    
    if (self.btnToVC2.translatesAutoresizingMaskIntoConstraints) {
        [self.btnToVC2 mas_makeConstraints:^(MASConstraintMaker *make) {
            make.center.equalTo(self.view);
            make.height.width.equalTo(@100);
        }];
    }
    
}

#pragma mark   getData
- (void)loadData {
    
}

#pragma mark   Method
-(void)toOther{
    [ArbPushUtil runtimePush:@"vc1" dic:@{} nav:self.navigationController];
}

#pragma mark


#pragma mark   geter/setter
-(UIButton *)btnToVC2{
    if (!_btnToVC2) {
        _btnToVC2 = [[UIButton alloc]init];
        _btnToVC2.backgroundColor = [UIColor redColor];
        [_btnToVC2 addTarget:self action:@selector(toOther) forControlEvents:UIControlEventTouchUpInside];
    }
    return _btnToVC2;
}

@end
